import pymysql
connect = pymysql.connect(
    host='127.0.0.1',
    db='study',
    user='root',
    password='mysql',
    port=3306,
    charset='utf8' )
# 创建游标
cur = connect.cursor()

# 删除单个表中数据
sql = 'delete from Student where name = "张三三"'

# 删除表中所有数据
sql = 'delete from Student'

